package TeamR3.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import TeamR3.dao.CustomerDao;
import TeamR3.entity.Customer;
import TeamR3.service.CustomerService;

@Service("customerService")
public class CustomerServiceImpl implements CustomerService {

	@Autowired
	private CustomerDao customerDao = null;

	public CustomerDao getCustomerDao() {
		return customerDao;
	}

	@Override
	public List<Customer> queryCustomerInfo(long identity, String customer_name) {
		return customerDao.queryCustomerInfo(identity, customer_name);
	}

	@Override
	public int addCustomerInfo(long identity, String customer_name,
			String customer_tel, int customer_point) {
		return customerDao.addCustomerInfo(identity, customer_name,
				customer_tel, customer_point);
	}

	@Override
	public int modifyCustomerInfo(long identity, String customer_name,
			String customer_tel, int customer_point) {
		return customerDao.modifyCustomerInfo(identity, customer_name,
				customer_tel, customer_point);
	}

	@Override
	public int delCustomerInfo(long identity) {
		return customerDao.delCustomerInfo(identity);
	}

}
